import java.util.Scanner;
public class er{
	public static void main(String args[])
	{
		Scanner cin =new Scanner(System.in);
		int a = cin.nextInt();
		if (a>0&&a<109)
		{
			if(a/100!=0)
			{
				a=a/100+a%100/10+a%100%10/1;
				System.out.println("3  "+a);
			}
			else if(a/10!=0)
			{
				a=a/10+a%10/1;
				System.out.println("2  "+a);
			}
			else 
			System.out.println("1  "+a);	
		}
		else
		System.out.println("sorry");

}
}